from base import BaseLogger;

class FileLogger(BaseLogger):
	def __init__(self, file = '/tmp/pyxbot.log', level = BaseLogger.ERROR):
		a = 2
		BaseLogger.__init__(self, level = level);
		self.file  = open(file,'a');
		self.write(self.level,'starting log');

	def write(self, level, message):
		if self.filter(level):
			print >> self.file, self.format(level, message);

klass = FileLogger;
